# -*- coding: utf-8 -*-#
#-------------------------------------------------------------------------------
# 建立者:        潘炎珍  
# Name:         test08
# Description:
# Author:       98745
# Date:         2019/3/9
#-------------------------------------------------------------------------------
i=2
def funca(x):
    print('funca')
    index = 2
    def funcb(y=0):
        rt=0
        print('funcb')
        if y:
            rt=x+y*i
        else:
            rt=x*index*i
        return rt
    return funcb
funcc=funca(3)
print('funcc:',type(funcc))
r=funcc(6)
print(r)
print('------------------')
r2=funcc()
print(r2)
# r2=funca(3)(6)  #柯里化
# print(r2)
# r3=funca(3)()  #柯里化
# print(r3)